package com.health.dao;

import com.health.pojo.Order;
import com.health.pojo.OrderList;
import com.health.pojo.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * @Classname CheckItemGroupDao
 * @Description TODO
 * @Version 1.0.0
 * @Date 2023/3/16 10:14
 * @Author RainGrd
 */
public interface OrderDao {

    int add(Order order);

    List<Order> findByCondition(Order order);

    Integer findOrderCountByDate(String date);

    Integer findOrderCountAfterDate(String date);

    Integer findVisitsCountByDate(String date);

    Integer findVisitsCountAfterDate(String date);

    List<Map> findHotSetmeal();

    List<OrderList> selectOrderByCondition(@Param("queryString") String queryString,@Param("user") User user);

    Long selectTotalByOrderId(@Param("queryString") String queryString);

    int arrived(Integer id);

    int deleteByMemberId(Integer memberId);

    //    Order
    Order selectOrderByMemberIdAndOrderStatus(
            @Param("memberId") Integer memberId,@Param("setmealId") Integer setmealId);

    Order selectOrderByMemberId(
            @Param("memberId")
            Integer memberId);

    int deleteById(Integer id);
}
